package com.ruoyi.work.domain;

import java.math.BigDecimal;
import java.util.Date;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.ruoyi.common.core.domain.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import com.ruoyi.common.annotation.Excel;
import org.springframework.web.jsf.FacesContextUtils;

/**
 * 车辆位置对象 tb_location_train
 *
 * @author szm
 * @date 2025-09-28
 */
@Data
@TableName("tb_location_train")
@ApiModel(value = "TbLocationTrain对象", description = "车辆位置")
public class TbLocationTrain extends BaseEntity {
    private static final long serialVersionUID = 1L;

    /** 主键 */
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    private String id;

    /** 消息Id */
    @Excel(name = "消息Id")
    @ApiModelProperty("消息Id")
    @TableField(value = "msg_id")
    private Integer msgId;

    /** 任务编号 */
    @Excel(name = "任务编号")
    @ApiModelProperty("任务编号")
    @TableField(value = "work_no")
    private String workNo;

    /** 终端编号 */
    @Excel(name = "终端编号")
    @ApiModelProperty("终端编号")
    @TableField(value = "termina_phone")
    private String terminaPhone;

    /** 车辆编号 */
    @Excel(name = "车辆编号")
    @ApiModelProperty("车辆编号")
    @TableField(value = "train_no")
    private String trainNo;

    /** 经度 */
    @Excel(name = "经度")
    @ApiModelProperty("经度")
    @TableField(value = "longitude")
    private String longitude;

    /** 维度 */
    @Excel(name = "维度")
    @ApiModelProperty("维度")
    @TableField(value = "latitude")
    private String latitude;

    /** 地点名称 */
    @Excel(name = "地点名称")
    @ApiModelProperty("地点名称")
    @TableField(value = "location_name")
    private String locationName;

    /** 电量 */
    @Excel(name = "电量")
    @ApiModelProperty("电量")
    @TableField(value = "electricity")
    private String electricity;

    /** 最后写入时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "最后写入时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty("最后写入时间")
    @TableField(value = "last_time")
    private Date lastTime;

    /** 告警信息 */
    @Excel(name = "告警信息")
    @ApiModelProperty("告警信息")
    @TableField(value = "warning_flag_field")
    private String warningFlagField;

    /** 告警状态 */
    @Excel(name = "告警状态")
    @ApiModelProperty("告警状态")
    @TableField(value = "status_field")
    private String statusField;

    /** 海拔 */
    @Excel(name = "海拔")
    @ApiModelProperty("海拔")
    @TableField(value = "elevation")
    private String elevation;

    /** 速度 */
    @Excel(name = "速度")
    @ApiModelProperty("速度")
    @TableField(value = "speed")
    private BigDecimal speed;

    /** 方向 */
    @Excel(name = "方向")
    @ApiModelProperty("方向")
    @TableField(value = "direction")
    private Integer direction;

    /** 状态 */
    @Excel(name = "状态")
    @ApiModelProperty("状态")
    @TableField(value = "status")
    private String status;

    @TableField(exist = false)
    private String lineName;

}
